package com.htthorizon.system.controller;

import com.htthorizon.system.excel.service.UserExcelService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.multipart.MultipartFile;

import java.io.IOException;

/**
 * @author Brilliant
 */
@RestController
@RequestMapping("/excel")
public class FileController {

    @Autowired
    private UserExcelService userExcelService;

    @PostMapping("/user")
    public void user(@RequestParam("file") MultipartFile file) throws IOException {
      boolean result=  userExcelService.uploadUserExcel(file);
    }
}
